package com.xt.dao;

import com.xt.bean.Specialty;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;

/**
 * Created by XT on 2018/5/3.
 */
public interface SpecialtyRepository extends MongoRepository<Specialty, String> {

    Page<Specialty> findByDepartmentIdAndNameLike(String departmentId, String name, Pageable pageable);

    Page<Specialty> findByDepartmentId(String departmentId,Pageable pageable);

    Page<Specialty> findByNameLike(String name,Pageable pageable);

}
